package com.aacar.dao.base;

import java.io.Serializable;

import javax.annotation.PostConstruct;
import javax.annotation.Resource;

import org.apache.ibatis.session.SqlSessionFactory;
/**
 * @author fei.tang
 */
public abstract class CommonBaseDao <E,PK extends Serializable> extends BaseDao<E, Serializable>{
	
	@Resource(name="sqlSessionFactory")
	private SqlSessionFactory sqlSessionFactory;

	public void setSqlSessionFactory(SqlSessionFactory sqlSessionFactory) {
		this.sqlSessionFactory = sqlSessionFactory;
	}

	@PostConstruct  
    public void injectSqlMapClient() {   
        super.setSqlSessionFactory(sqlSessionFactory);
    }
}
